from importlib.resources import contents

f = open("../file/word.txt",'r')
# 模式 r 读取
# 模式

# 按字节读取
# content = f.read()
# 按行读取
# content = f.readline()
# 多行读取 返回列表
content = f.readlines()
print(content)
# ['Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n', 'Writing a crawler\n']



f.close()
